import java.util.Collection;
import java.util.Enumeration;
import java.util.Map;
import java.util.Properties;

/**
 * <p>Title:</p>
 * <p>Description:</p>
 *
 * @author zhanghong
 * @date 2021/12/22
 */
public class Environment {
    public static void main(String[] args) {
//        Properties properties = System.getProperties();
//        Enumeration<?> enumeration = properties.propertyNames();
//        while (enumeration.hasMoreElements()){
//            System.out.println(String.format("%s------>%s",enumeration.nextElement(),properties.getProperty((String)enumeration.nextElement())));
//        }

        Map<String, String> getenv = System.getenv();
        Collection<String> values = getenv.values();
        for (String value : values) {
            System.out.println(value);
        }
    }
}
